package com.sjsoft.chat.video;

import com.sjsoft.app.video.R;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;

public class SplashActivity extends Activity {
		
	 
	 @Override
		public void onCreate(Bundle savedInstanceState) {
			super.onCreate(savedInstanceState);
			
			setContentView(R.layout.splash_screen);
				//reset content
					
				Thread splashTread = new Thread() {
					int waited = 0;
					@Override
					public void run() {
						try {
							
							while ( waited < Definitions.SPLASH_TIME) {
								sleep(100);	
								waited += 100;
								
							}
						} catch (InterruptedException e) {
							// do nothing
						} finally {
							trainsitionView();
						}
					}
				};
				splashTread.start();
			
		}

	
	   public void trainsitionView()
	   {		 
		    //Log.e("SplashActivity", "trainsitionView == null:-------------------------");
		    startActivity(new Intent(SplashActivity.this, mainTab.class));		   	
	        finish();
	   }

		
}

